﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Staff.aspx.cs" Inherits="SJZD_TypeManage" %>
<%@ Register Src="../usercontrol/PageNavigator.ascx" TagName="PageNavigator" TagPrefix="uc1" %>
<html >
<head id="Head1" runat="server">
<title>商品品牌管理</title>
<link href="../css/adminCss.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../js/changerows.js"></script>
<script type="text/javascript">
function CheckAll(form) {
    for (var i=0;i<form.elements.length;i++) {
	    var e = form.elements[i];
	    if (e.name != 'chkall' && e.type=='checkbox')
		    e.checked = form.chkall.checked;
    }
}
</script>
<link href="../js/loading.css" rel="stylesheet" type="text/css" />
</head>
<script type="text/javascript" src="../js/loading.js" charset="gb2312"></script>
<body style="text-align: center">
    <form id="form1" runat="server">
<table width="99%" border="0" cellpadding="0" cellspacing="0">
    <tr> 
        <td width="31" height="22"><img src="../images/module.gif" width="20" height="22"></td>
        <td><asp:Label ID="lblwz" runat="server"></asp:Label></td>
    </tr>
</table>
<table width="99%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td bgcolor="#3CB6E5" height="5px"></td>
  </tr>
</table>
<table width="99%" border="0" cellpadding="0" cellspacing="0">
    <tr> 
        <td width="80%" align="right" style="text-align: right">
<img src="../images/search.gif" alt="搜索" width="16" height="16"/>员工姓名：<asp:TextBox
            ID="txtselecName" runat="server" CssClass="input1" Width="100px"　></asp:TextBox>
        所属职务：<asp:DropDownList ID="StaffWork" runat="server">
        </asp:DropDownList>
        所属部门：<asp:DropDownList ID="ddrDepartment" runat="server">
        </asp:DropDownList>
            在职状态：<asp:DropDownList ID="AuditState" runat="server">
                <asp:ListItem Value="">全部</asp:ListItem>
                <asp:ListItem Value="1">在职</asp:ListItem>
                <asp:ListItem Value="0">离职</asp:ListItem>
            </asp:DropDownList>
        <asp:Button ID="btnSelec" runat="server" Text=" 搜索 " CssClass="submit" CausesValidation="False" OnClick="btnSelec_Click"/></td>
    </tr>
</table>
<table width="99%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td bgcolor="#3CB6E5" height="5px"></td>
  </tr>
</table>
        <asp:GridView ID="GvDataStaff" runat="server" CssClass="gridview" Width="99%" AutoGenerateColumns="False"
            DataKeyNames="StaffId" RowStyle-HorizontalAlign="center" EmptyDataText="没有数据" OnRowDataBound="GvDataStaff_RowDataBound" >
             <RowStyle Height="25px" />
            <Columns>
                <asp:BoundField DataField="StaffId" HeaderText="员工Id"/>
                <asp:BoundField DataField="StaffName" HeaderText="员工姓名" />
                <asp:BoundField DataField="Deptname" HeaderText="所属部门" />
                <asp:BoundField DataField="WTitle" HeaderText="所任职务" />
                <asp:BoundField DataField="StaffTel" HeaderText="联系电话" />
                <asp:TemplateField HeaderText="基本工资(元)">
                    <ItemTemplate>
                        <asp:Label ID="StaffSalary" runat="server" Text= '<%# Bind("StaffSalary","{0:f2}") %>'></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="WageDate" HeaderText="入职时间" />
                <asp:BoundField DataField="EditUserName" HeaderText="编辑人" />
                 <asp:BoundField DataField="StaffOrder" HeaderText="员工排序" />
                 <asp:BoundField DataField="salesNum" HeaderText="销售记录" />
                 <asp:BoundField DataField="AuditState" HeaderText="在职状态" />
                <asp:TemplateField HeaderText="操作">
                    <ItemTemplate>
                        <asp:LinkButton ID="lnkbtnEdit" CssClass="lnkbtn" runat="server" CommandArgument='<%#Eval("StaffId") %>' OnClick="lnkbtnEdit_Click" >修改</asp:LinkButton>
                        <asp:LinkButton ID="lnkbtnFlag" CssClass="lnkbtn" runat="server" CommandArgument='<%#Eval("StaffId") %>' OnClick="lnkbtnFlag_Click" >审核</asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="选择"><ItemTemplate>
                    <asp:CheckBox ID="chkDelete"  runat="server" />
                </ItemTemplate>
                </asp:TemplateField>
                
            </Columns>
            <RowStyle HorizontalAlign="Center" />
            <EmptyDataRowStyle ForeColor="Red" HorizontalAlign="Center" />
        </asp:GridView>
        <table width="99%" border="0" cellspacing="0" cellpadding="0">
        <tr>
                <td align="center">
                  <uc1:PageNavigator ID="PageNavigator1" DataId="GvDataStaff" ShowType="Num" ConnectionString="connstr" PageSize="20" runat="server" />
                </td>
            <td height="5" align="right"><input type="checkbox" name="chkall"  onclick="CheckAll(this.form)" value="on"><font color="#FF0000">全选</font>&nbsp;
            <asp:Button ID="btnAdd" runat="server" Text="添加" CssClass="submit" CausesValidation="False" OnClick="btnAdd_Click"   />&nbsp;<asp:Button  ID="btnallflag" OnClick="btnallflag_Click" runat="server" Text="批审" CssClass="submit"  OnClientClick="return confirm('确定要审核吗?')" />&nbsp;<asp:Button  ID="btndel" runat="server" Text="删除" CssClass="submit"  OnClick="btndel_Click" OnClientClick="return confirm('确定要删除吗?')" />
        
        </td>
      </tr>
      </table>
        
       
      <asp:Label ID ="err" runat="server" ForeColor="Red"></asp:Label>
       <asp:HiddenField ID="hfxs" runat="server" />
        <asp:HiddenField ID="hfcheck" runat="server" />
         <asp:HiddenField ID="hfuserId" runat="server" />
         <asp:HiddenField ID="hfLevels" runat="server" />
       
    </form>
</body>
</html>
<script language="javascript"><!--
//senfe("表格名称","奇数行背景","偶数行背景","鼠标经过背景","点击后背景");
senfe("GvDataStaff","#ECF9FC","#FFFFFF","#D6F1F8");
--></script>